@using ApiGenerator
@using System.Collections.Generic
@using System.Collections.ObjectModel
@using ApiGenerator.Domain.Code
@using ApiGenerator.Domain.Specification
@inherits ApiGenerator.CodeTemplatePage<KeyValuePair<string, ReadOnlyCollection<ApiEndpoint>>>
@{
	KeyValuePair<string, ReadOnlyCollection<ApiEndpoint>> model = Model;
	string ns = model.Key;
	var endpoints = model.Value;
}
@{ await IncludeAsync("GeneratorNotice.cshtml", model); }
// ReSharper disable RedundantUsingDirective
using System;
using System.Threading;
using System.Threading.Tasks;
using Elasticsearch.Net.@(CsharpNames.ApiNamespace).@(ns)@(CsharpNames.ApiNamespaceSuffix);

// ReSharper disable once CheckNamespace
// ReSharper disable RedundantTypeArgumentsOfMethod
namespace Nest.@(CsharpNames.ApiNamespace).@(ns)@(CsharpNames.ApiNamespaceSuffix)
{
	///<summary>
	/// @(ns.SplitPascalCase()) APIs.
	/// <para>Not intended to be instantiated directly. Use the <see cref="IElasticClient.@ns"/> property
	/// on <see cref="IElasticClient"/>.
	///</para>
	///</summary>
	public class @(CsharpNames.HighLevelClientNamespacePrefix)@(model.Key)@(CsharpNames.ClientNamespaceSuffix) : NamespacedClientProxy
	{
		internal @(CsharpNames.HighLevelClientNamespacePrefix)@(model.Key)@(CsharpNames.ClientNamespaceSuffix)(ElasticClient client) : base(client) {}
		@foreach(var e in endpoints)
		{
			await IncludeAsync("HighLevel/Client/Implementation/MethodImplementation.cshtml", e.HighLevelModel);
		}
	}
}
